package la.iok.hzsvn.lewin.movie.service;

import la.iok.hzsvn.lewin.movie.core.Token;
import la.iok.hzsvn.lewin.movie.core.movieservice.param.NameSequenceParam;
import la.iok.hzsvn.lewin.movie.entity.BookChapter;
import la.iok.hzsvn.lewin.movie.model.BookChapterVo;
import la.iok.hzsvn.lewin.mybatis.service.BaseService;
import la.iok.hzsvn.share.annotations.NotNull;
import la.iok.hzsvn.share.annotations.NotNullElement;
import la.iok.hzsvn.share.annotations.Nullable;

import java.util.List;

public interface BookChapterService extends BaseService<BookChapter,Long> {
    Long save(@NotNull Token token, @NotNull Long movieId, @NotNull NameSequenceParam param);
    void update(@NotNull Token token, @NotNull Long id, @NotNull NameSequenceParam param);
    void delete(@NotNull Token token, @NotNull Long id);
    @NotNull
    @NotNullElement
    List<BookChapterVo> movieChapters(@NotNull Token token,@Nullable Long movieId);

    /**
     * 查询章节,不验证权限
     * @param movieId 剧本id
     * @return 章节列表
     */
    @NotNull
    @NotNullElement
    List<BookChapter> movieChapters(@Nullable Long movieId);
}
